Menu

Play Time-based Player Promotions

Zathrus Writer

Play Time-based Player Promotions

This is an event handling function that promotes players (i.e. adds them to different groups) once they played certain time on the server.


Plugin dependencies

Time-based Player Promotions require a permission plugin to be installed on your server (such as PermissionsEX), as the built-in Bukkit permission system does not support permission groups.

Since there are many permission plugins, it would be inefficient for CommandsEX to try and implement them all, as there already is a plugin that does exactly that. This plugin is called Vault and you will need to have it installed on your server for Time-based Player Promotions to work.


Configuration

There are 3 config options added to accommodate player time-based promotions:

  • timedPromoteTaskTime - time (in seconds) after which the plugins should periodically check how much time players played on the server and promote them based on these findings. Default: 180 (3 minutes)
  • timedPromote - time (in seconds) a player must play on the server before being auto-promoted to each group. There is a default example value provided in the config file and below this text for your reference.
  • timedPromoteExclude - players in these groups will be excluded from timed auto-promotions (useful for admins, moderators, ...) Default: [admin]

Default value of timedPromote option:

timedPromote:
  default: 0

Example usage:

timedPromote:
  wanderer: 500 # add player to group wanderer after 500 seconds of playtime
  member: 3600 # add player to group wanderer after 3600 seconds of playtime

PLEASE NOTE: value of timedPromoteTaskTime must not be lower than 180 seconds, since this is the time after which CommandsEX saves players' play times into database. It this option is set to a lower, it will automatically be raised.


/cex_time2rank

  • Description: Allows player to see how much time is left until they get auto-promoted.
  • Usage: /cex_time2rank
  • Permission node: cex.time2rank
  • Default permission: everyone
  • Aliases: time2rank
  • Location in JAR file: com/github/zathrus_writer/commandsex/commands/Command_cex_time2rank.class

How to remove this feature

Should there be a need to manually remove this feature from the JAR file, the following files must be removed: com/github/zathrus_writer/commandsex/handlers/Handler_playtimepromote.class
com/github/zathrus_writer/commandsex/commands/Command_cex_time2rank.class


Related

Wiki: CommandsEX CraftBukkit plugin Wiki

MongoDB Logo MongoDB